找传奇、传世资源到传世资源站!

vs2010 C# winform皮肤主题切换源码

8.5玩家评分(1人评分)
下载后可评
介绍 评论 失效链接反馈

vs2010 C# winform皮肤主题切换源码 C#语言基础-第1张vs2010 C# winform皮肤主题切换源码 C#语言基础-第2张vs2010 C# winform皮肤主题切换源码 C#语言基础-第3张vs2010 C# winform皮肤主题切换源码 C#语言基础-第4张vs2010 C# winform皮肤主题切换源码 C#语言基础-第5张using System;using System.Collections.Generic;using System.ComponentModel;using System.Data;using System.Drawing;using System.Linq;using System.Text;using System.Windows.Forms;using System.IO;using System.Collections;namespace UseSkin{ public partial class Form1 : Form { Sunisoft.IrisSkin.SkinEngine skin = new Sunisoft.IrisSkin.SkinEngine(); int intCount = 0; ArrayList arraylist = new ArrayList(); public Form1() { InitializeComponent(); } private void Form1_Load(object sender, EventArgs e) { foreach (string filename in Directory.GetFiles(Directory.GetCurrentDirectory() "\\skins")) { arraylist.Add(filename); } } private void button1_Click(object sender, EventArgs e) { changeSkin( true); } private void button2_Click(object sender, EventArgs e) { changeSkin( false ); } private void changeSkin(bool bolplus) { if (bolplus) { if (intCount < arraylist.Count) intCount ; else intCount = 0; } else { if (intCount > 0) { intCount--; } else { intCount = arraylist.Count; } } string skinname = ""; for(int i=0;i<arraylist .Count ;i ) { if (i ==(intCount-1)) { skin.SkinFile = arraylist[i].ToString(); skinname = arraylist[i].ToString(); skin.Active = true; label1.Text = "第" intCount.ToString() "个皮肤"; label2.Text = skinname; break; } } } private void toolStripButton1_Click(object sender, EventArgs e) { Form2 f = new Form2(); f.ShowDialog(); } private void button3_Click(object sender, EventArgs e) { File.Delete(label2.Text); } }}

评论

发表评论必须先登陆, 您可以 登陆 或者 注册新账号 !


在线咨询: 问题反馈
客服QQ:174666394

有问题请留言,看到后及时答复